package com.hyt.it.ogt.kq.main.controller.gov;

import com.baomidou.mybatisplus.extension.plugins.pagination.Page;
import com.hyt.common.apiInfor.ApiResponse;
import com.hyt.it.ogt.kq.common.config.exception.KqException;
import com.hyt.it.ogt.kq.common.gov.constant.ResponseCode;
import com.hyt.it.ogt.kq.main.controller.base.BaseController;
import com.hyt.it.ogt.kq.service.gov.model.param.AddExamAgreementParam;
import com.hyt.it.ogt.kq.service.gov.model.param.BehaviorAnalysisParam;
import com.hyt.it.ogt.kq.service.gov.model.vo.BehaviorAnalysisPageVo;
import com.hyt.it.ogt.kq.service.gov.service.IBehaviorAnalysisService;
import com.hyt.model.PageParam;
import io.swagger.annotations.Api;
import io.swagger.annotations.ApiOperation;
import io.swagger.annotations.ApiOperationSort;
import io.swagger.annotations.ApiSort;
import lombok.extern.slf4j.Slf4j;
import org.springframework.web.bind.annotation.*;

import javax.annotation.Resource;
import javax.validation.Valid;

@RestController
@Api(tags = "135.机考上传行为分析", value = "机考上传行为分析接口")
@ApiSort(value = 135)
@RequestMapping("/kw/gov/behaviorAnalysis")
@Slf4j
public class BehaviorAnalysisController extends BaseController {

    @Resource
    IBehaviorAnalysisService iBehaviorAnalysisService;


    @ApiOperationSort(value = 1)
    @ApiOperation(value = "135.1 查询行为分析", response = BehaviorAnalysisPageVo.class)
    @GetMapping("/queryPage")
    public ApiResponse<Page<BehaviorAnalysisPageVo>> queryPage(PageParam<BehaviorAnalysisPageVo> pageParam, BehaviorAnalysisParam param) {
        Page<BehaviorAnalysisPageVo> page = iBehaviorAnalysisService.queryPage(pageParam, param);
        return ApiResponse.<Page<BehaviorAnalysisPageVo>>builder().data(page).code(ResponseCode.SUCCESS.getCode()).build();
    }


}
